﻿@model Entity.ViewModels.UserOrFlowTypeModel
@{
    Layout = "~/Views/Shared/_Style.cshtml";
}

@*layer*@
<link href="~/js/lib/layui/dist/css/layui.css" rel="stylesheet" />
<script src="~/js/lib/jquery/jquery-3.2.1.js"></script>
<script src="~/js/lib/layui/dist/layui.js"></script>
<script src="~/js/content/tool.js"></script>
@*flow*@
<script type="text/javascript" src="~/js/lib/flow/plugin/jquery.min.js"></script>
<script type="text/javascript" src="~/js/lib/flow/codebase/GooFunc.js"></script>
<script type="text/javascript" src="~/js/lib/flow/plugin/json2.js"></script>
<link href="~/css/flow/default.css" rel="stylesheet" />
<script type="text/javascript" src="~/js/lib/flow/codebase/GooFlow.js"></script>
<script type="text/javascript" src="~/js/lib/flow/codebase/GooFlow.color.js"></script>
<link href="~/js/lib/flow/codebase/GooFlow.css" rel="stylesheet" />
<link href="~/css/flow/seeFlow.css" rel="stylesheet" />
<script src="~/js/content/flow/addFlow.js"></script>
<div class="layui-row">
    <div class="layui-tab layui-tab-brief" lay-filter="tab" style="margin: 0px">
        <ul class="layui-tab-title">
            <li class="layui-this">流程设计</li>
            <li>基本信息</li>
        </ul>
        <div class="layui-tab-content" style="height: 100px;">
            <div class="layui-tab-item layui-show">
                <span style="color:red;font-size:13px">注意：流程必须具有入口节点和结束节点</span>
                <div id="FlowId" style="margin:5px;float:left"></div>
                <form class="layui-form" action="" style="width:280px;  float: left;" id="propertyForm">
                    <input id="NodeStatu" type="hidden" />
                    <input id="ApprovalStatu" type="hidden" value="0" />
                    <fieldset class="layui-elem-field site-demo-button">
                        <legend>节点设置区</legend>
                        <br />
                        <div class="layui-form-item">
                            <label class="layui-form-label">节点名称</label>
                            <div class="layui-input-block">
                                <input type="text" name="NodeNames" autocomplete="off" id="NodeNames" placeholder="请输入节点名称" class="layui-input">
                            </div>
                            <br />
                            <label class="layui-form-label">节点编号</label>
                            <div class="layui-input-block">
                                <input type="text" name="NodeId" autocomplete="off" id="NodeId" placeholder="不可编辑" class="layui-input" readonly="readonly">
                            </div>
                            <br />
                            <label class="layui-form-label">节点类型</label>
                            <div class="layui-input-block">
                                <input type="text" name="NodeType" autocomplete="off" id="NodeType" placeholder="不可编辑" class="layui-input" readonly="readonly">
                            </div>
                            <br />
                        </div>
                    </fieldset>
                    <fieldset class="layui-elem-field site-demo-button" id="ApprovalShow">
                        <legend>审批设置区</legend>
                        <br />

                        <div style="width:280px">
                            <label class="layui-form-label">审批人</label>
                            <div class="layui-input-block">
                                <select name="ApprovalId" lay-verify="yz" lay-search="">
                                    <option value="">直接选择或搜索选择</option>
                                    @foreach (var item in Model.UserDto)
                                    {
                                        <option value="@item.UserId">@item.UserName (@item.DepartmentName)</option>
                                    }
                                </select>
                            </div>
                        </div>

                        <br />
                    </fieldset>
                    <div class="layui-form-item">
                        <div class="layui-input-block">
                            <br />
                            <input type="button" class="layui-btn" lay-submit="" lay-filter="submit" value="设置" />
                            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                        </div>
                    </div>
                </form>
            </div>
            <div class="layui-tab-item">
                <form class="layui-form" action="">
                    <fieldset class="layui-elem-field site-demo-button">
                        <legend>流程信息设置</legend>
                        <br />
                        <br />
                        <div class="layui-form-item">
                            <div class="layui-inline">
                                <label class="layui-form-label">流程名称</label>
                                <div class="layui-input-block">
                                    <input type="text" name="FlowName" lay-verify="yz" autocomplete="off" placeholder="请输入流程名称" class="layui-input" style="width:200px">
                                </div>
                            </div>
                            <div class="layui-inline">
                                <label class="layui-form-label">类型id</label>
                                <div class="layui-input-block">
                                    <select name="TypeId" lay-verify="yz" lay-search="">
                                        <option value="">直接选择或搜索选择</option>
                                        @foreach (var item in Model.FlowType)
                                        {
                                            <option value="@item.Id">@item.Name</option>
                                        }
                                    </select>
                                </div>
                            </div>
                            <div class="layui-inline">
                                <label class="layui-form-label">表单选择</label>
                                <div class="layui-input-block">
                                    <select name="Formid" lay-verify="yz" lay-search=""  lay-filter="formId" id="FormsId">
                                        <option value="">直接选择或搜索选择</option>
                                        @foreach (var item in Model.Forms)
                                        {
                                            <option value="@item.Id">@item.Name</option>
                                        }
                                    </select>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item" style="margin:0  0 0 40% ">
                            <div class="layui-input-block">
                                <br />
                                <button class="layui-btn" lay-submit="" lay-filter="submit2">立即提交</button>
                                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                            </div>
                        </div>
                    </fieldset>

                    <fieldset class="layui-elem-field site-demo-button" style="width:1000px;height:425px">
                        <legend>表单样式预览</legend>
                        <br />
                        <div class="container" style="width: 750px">
                            <div id="content"></div>
                        </div>
                    </fieldset>
                </form>
            </div>
        </div>
        <br />
        <br />
    </div>
</div>


